/*
 * godos.h
 *
 *  Created on: 12.05.2011
 *      Author: Thomas Opolka
 *     Version: 0.8
 */

#ifndef GODOS_H_
#define GODOS_H_

#include <stdbool.h>
#include <stdint.h>

#include "fixedpoint.h"


typedef uint32_t timeSinceStart_t;  /* time type */
typedef int16_t acceleration_t;     /* acceleration type DEPRECATED */
typedef int16_t velotype_t;         /* velocity type DEPRECATED */


/*
 * Updates g_GVelocity
 */
bool bGUpdateVelocity(volatile timeSinceStart_t *pdwTimeNow, fixedpoint_t *pwAcceleration, fixedpoint_t *pwGVelocity);

/*
 * Updates g_OVelocity
 */
bool bOUpdateVelocity(volatile timeSinceStart_t *pdwTimeNow, fixedpoint_t *pwRevolutionLeft, fixedpoint_t *pwRevolutionRight, fixedpoint_t *pwOVelocity, fixedpoint_t *pwGVelocity);


#endif /* GODOS_H_ */
